Carbon


GetFrontProcess

Header: Processes.h Carbon status: Supported

Gets the process serial number of the front process.

OSErr GetFrontProcess (
    ProcessSerialNumber *PSN
);
PSN

On return, a pointer to the process serial number of the process running in the foreground.

function result

A result code. If no process is running in the foreground, GetFrontProcess returns the result code procNotFound.

DISCUSSION

You can use this function to determine if your process or some other process is in the foreground. You can use the process serial number returned in the PSN parameter in other Process Manager functions.

AVAILABILITY

Supported in Carbon. Available in CarbonLib 1.0 and later when InterfaceLib 7.1 or later is installed. Exported by CarbonLib 1.0 and later and by InterfaceLib 7.1 and later.


© 2000 Apple Computer, Inc. — (Last Updated 4/14/2000)